<!DOCTYPE html>
<html lang="en">
<!--头部信息-->
<head>
    <meta charset="utf-8">
    <title>瘟疫详情</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="../../lib/layui-v2.5.5/css/layui.css" media="all">
    <link rel="stylesheet" href="../../css/public.css" media="all">

    <script src="../../lib/layui-v2.5.5/layui.js" charset="utf-8"></script>
</head>
<!--瘟疫详情-->
<body>
<div class="layuimini-container">
    <div class="layuimini-main">

        <div class="layui-row">
            <div class="layui-col-xs6">
                <div class="grid-demo grid-demo-bg1">
                    <!--瘟疫名称-->
                    <div class="layui-form-item layui-form-text">
                        <label class="layui-form-label">瘟疫名称：</label>
                        <div class="layui-input-block" id="name" style="width: 80%">
                            <label name="name" class="layui-form-label-col "></label>
                        </div>
                    </div>
                </div>
            </div>
            <div class="layui-col-xs6">
                <div class="grid-demo">

                </div>
            </div>
        </div>

        <div class="layui-row">
            <div class="layui-col-xs6">
                <div class="grid-demo grid-demo-bg1">
                    <!--瘟疫源头-->
                    <div class="layui-form-item layui-form-text">
                        <label class="layui-form-label">瘟疫源头：</label>
                        <div class="layui-input-block" id="names" style="width: 80%">
                            <label name="names" class="layui-form-label-col "></label>
                        </div>
                    </div>
                </div>
            </div>
            <div class="layui-col-xs6">
                <div class="grid-demo">
                    <!--死亡人数-->
                    <div class="layui-form-item layui-form-text">
                        <label class="layui-form-label">死亡人数：</label>
                        <div class="layui-input-block" id="dienumber" style="width: 80%">
                            <label name="dienumber" class="layui-form-label-col "></label>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="layui-row">
            <div class="layui-col-xs6">
                <div class="grid-demo grid-demo-bg1">
                    <!--瘟疫地区-->
                    <div class="layui-form-item layui-form-text">
                        <label class="layui-form-label">事发地区：</label>
                        <div class="layui-input-block" id="area" style="width: 80%">
                            <label name="area" class="layui-form-label-col "></label>
                        </div>
                    </div>
                </div>
            </div>
            <div class="layui-col-xs6">
                <div class="grid-demo">
                    <!--瘟疫时间-->
                    <div class="layui-form-item layui-form-text">
                        <label class="layui-form-label">瘟疫时间：</label>
                        <div class="layui-input-block" id="happenTime" style="width: 80%">
                            <label name="happenTime" class="layui-form-label-col "></label>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div id="demo2"></div>
        <!--创建表格-->
        <table class="layui-hide" id="currentTableId" lay-filter="currentTableFilter"></table>
    </div>
</div>

<!--隐藏域-->
<div style="display: none">
    <input type="text" value="" id="value">
</div>

<script>
    layui.use(['laypage', 'table', 'jquery'], function () {
        var $ = layui.jquery,
            laypage = layui.laypage,
            table = layui.table;

        /*表格数据渲染*/
        table.render({
            elem: '#currentTableId',
            url: '/getSwmdList/' + $('#value').val(),
            cellMinWidth: 50,
            height: 351,
            limit: 7,
            limits: [7, 14, 21, 28, 35],
            method: 'GET',
            text: {
                none: '暂时没有数据哦！'
            },
            cols: [
                [
                    {type: 'numbers', width: 50, title: '序号', align: "center"}
                    , {field: 'id', title: 'ID', hide: true, align: "center"}
                    , {field: 'did', title: '感染者ID', hide: true, align: "center"}
                    , {field: 'dname', title: '姓名', align: "center"}
                    , {field: 'dsex', title: '性别', align: "center"}
                    , {
                    field: 'dage', title: '年龄', sort: true, align: "center", templet: function (d) {
                        return d.dage += "岁";
                    }
                }
                    , {field: 'darea', title: '地区', align: "center"}
                    , {field: 'dtype', title: '类别', align: "center"}
                    , {field: 'dfzid', title: '分组ID', hide: true, align: "center"}
                    , {field: 'dtime', width: 180, title: '瘟疫时间', sort: true, align: "center"}
                ]
            ],
            page: true,
            id: "testId"
        });
    });

</script>

</body>
</html>